package be.nepherte.movmanager.client;

import java.util.ArrayList;
import com.google.gwt.user.client.rpc.AsyncCallback;

/**
 * This class represents the asynchronous version of the database service. All methods defined in DatabaseService should also be in this interface. 
 * One must use this interface to use RPC calls with the database service. When the service execution is finished, it will notify the AsyncCallback 
 * object that the result is available.
 * <p>
 * This file is part of MovManager.
 * </p>
 * <p>
 * MovManager is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 * </p>
 * <p>
 * MovManager is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 * </p>
 * <p>
 * You should have received a copy of the GNU General Public License
 * along with MovManager.  If not, see <a href="http://www.gnu.org/licenses/">http://www.gnu.org/licenses</a>.
 * </p>
 * 
 * @author	Bart Verhoeven
 * @since	23/05/2009
 * @version 0.1
 */
public interface DatabaseServiceAsync {

	/**
	 * Get a list with all the movies available in the database.
	 * 
	 * @param	callback
	 * 			the object that should be notified when the result is available
	 */
	public void getMovies(AsyncCallback<ArrayList<Movie>> callback);
	
	/**
	 * Get a list with all genres linked to one or more movies in the database.
	 * 
	 * @param	callback
	 * 			the object that should be notified when the result is available
	 */
	public void getGenres(AsyncCallback<ArrayList<String>> callback); 
}
